<?php 
namespace app\site\validate;
use think\Validate;

class SiteOperate extends Validate
{
 	/**
 	 * 规则
 	 * @var [type]
 	 */
 	protected $rule = [
 		'site_id' => 'require',
 		'log_id' => 'require',
 		'action' => 'require',
 		'unit' => 'require',
 		'number' => 'require|number',
 	];

 	/**
 	 * 提示信息
 	 * @var [type]
 	 */
 	protected $message = [
 		'site_id' => '缺少站点名称',
 		'log_id' => '缺少财务记录单号',
 		'action' => '缺少操作类型',
 		'unit' => '缺少计费方式',
 		'number.require' => '缺少计费时长',
 		'number.number' => '计费时长必须是数字',
 		
 	];
	/**
 	 * 场景
 	 * @var [type]
 	 */
 	protected $scene =[
 		'create' => ['site_id','log_id','action','unit','number']
 	];

 }